Component({
	properties: {
		imgUrl: {
			type: String,
			value:
				"https://images.unsplash.com/photo-1516203294340-5ba5f612dc6a?ixlib=rb-0.3.5&ixid=eyJhcHBfaWQiOjEyMDd9&s=1b79294f231ab4799218e82818a07de1&auto=format&fit=crop&w=500&q=60",
			observer(newVal, oldVal) {
				this._initStatus();
			}
		},
		lazyLoad: {
			type: Boolean,
			value: false
		},
		mode: {
			type: String,
			value: "widthFix"
		}
	},
	data: {
		status: "LOAD" //LOAD 加载中 SUCCESS 加载完成 ERROR 加载失败
	},
	attached() {},
	ready() {},
	methods: {
		_initStatus() {
			this.setData({
				status: "LOAD"
			});
		},
		_loadError(e) {
			this.setData({
				status: "ERROR"
			});
		},
		_loadSuccess(e) {
			this.setData({ status: "SUCCESS" });
		}
	}
});
